package org.ihelpuoo.weboo.bean;

import org.ihelpuoo.lang.StringUtils;

public class ControllerBean
{

	private String				type;
	private String				modules;

	private String[]			_names;
	
	public String getModules()
	{
		return modules;
	}

	public void setModules(String forModules)
	{
		this.modules = StringUtils.trim(forModules);
	}

	public String getType()
	{
		return type;
	}

	public void setType(String type)
	{
		this.type = StringUtils.trim(type);
		if (null != this.type && this.type.length() == 0)
			this.type = null;
	}

	public String[] handleModuleNames()
	{
		if (null == modules)
			return null;
		if (null == _names)
		{
			_names = StringUtils.splitIgnoreBlank(modules,"[,]");
		}
		return _names;
	}

}
